# 合并后解决冲突
import pytest,logging


def set_log():
    logging.basicConfig(level=logging.DEBUG,
                        format='%(message)s %(levelname)s %(asctime)s %(lineno)s %(filename)s',
                        filemode='w+',
                        filename='zk3.log')
    handler = logging.StreamHandler()
    handler.setLevel(logging.DEBUG)

    format1 = logging.Formatter('%(message)s %(levelname)s %(asctime)s %(lineno)s %(filename)s')
    handler.setFormatter(format1)

    logger = logging.getLogger()
    logger.addHandler(handler)

if __name__ == '__main__':
    set_log()
    pytest.main(['test_login.py','-s'])


